<include file="public@header"/>

</head>

<style>
    .content{
        font-weight: normal;
    }

</style>

<body>

<h3 style="margin-left: 20px;"><strong>查看详情</strong></h3>
<!-- 模态框（Modal） -->
<div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
    <div class="modal-dialog">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">
                    &times;
                </button>
                <h4 class="modal-title" id="myModalLabel">
                    请输入拒绝理由
                </h4>
            </div>
            <div class="modal-body">
                <textarea id="content" class="form-control" rows="3"></textarea>
                <input type="hidden" id="uid" value="{$info.id}">
                <button onclick="submitReason()" data-dismiss="modal" style="margin-right: 50px; outline: 0px; margin-top: 20px" type="button" class="btn btn-primary">提交</button>
            </div>
        </div>
    </div>
</div>
<div>
    <div class="row">
        <div class="col-md-3" style="margin-left: 20px; margin-top: 30px; display: inline-block">
            <p class="content">受理单位: {$info.shoulidanwei}</p>
            <p class="content">姓名   : {$info.name}</p>
            <p class="content">证件名称: {$info.zhengjiantype}</p>
            <p class="content">证件号码: {$info.zhengjiannumber}</p>
            <p class="content">联系地址: {$info.address}</p>
        </div>
        <div class="col-md-4" style="margin-left: 20px; margin-top: 30px; display: inline-block">
            <p class="content">申请人类型: {$info.shenqingrentype}</p>
            <p class="content">电子邮件   : {$info.email}</p>
            <p class="content">工作单位: {$info.gongzuodanwei}</p>
            <p class="content">联系电话: {$info.tel}</p>
            <p class="content">邮政编码: {$info.youzhengbianma}</p>
        </div>
    </div>
    <div style="margin-left: 20px;margin-right: 20px;">
        <p class="content">标题: {$info.xinxibiaoti}</p>
        <p class="content">内容   : {$info.xinxineirong}</p>
        <p class="content">获取信息的方式: {$info.huoqufangshi}</p>
        <p class="content">是否申请减免费用: {$info.shifoujianmian}</p>
        <p class="content">是否接受其它方式: {$info.qitafangshi}</p>
        <if condition="$type == 3">
            <p class="content" style="color: red">拒绝理由: {$info.yuanyin}</p>
        </if>
    </div>

    <if condition="$type != 2">
        <div style="margin-bottom: 50px;">
            <a href="{:url('Applyopen/changeStatus')}?id={$info.id}&type={$type}" style="margin-left: 20px; margin-right: 50px; outline: 0px;" type="button" class="btn btn-primary">同意</a>
            <if condition="$type != 3">
                <a style="outline: 0px" type="button" class="btn btn-danger" data-toggle="modal" data-target="#myModal">拒绝</a>
            </if>
        </div>
    </if>


</div>

<script src="https://cdn.bootcss.com/jquery/3.3.1/jquery.js"></script>
<script src="__STATIC__/js/admin.js"></script>
<script src="__STATIC__/js/layer/layer.js"></script>

<script>

    function submitReason() {
        var content = $('#content').val();
        if (content.length == 0){
            layer.msg('输入不能为空');
            return;
        }
        var uid = $('#uid').val();
        $.ajax({
            type: 'GET',
            data: {'id':uid, 'yuanyin':content},
            url : "{:url('Applyopen/refuseVerify')}",
            success: function (res) {
                window.location.href = "{:url('Applyopen/getAllUnVerify')}"
            },
            error: function (err) {
                console.log(err);
            }
        })

    }

</script>



</body>
</html>